import java.util.*;

class Circle{
    private int radius;

    @Override
    public String toString() {
        return "Circle [" +
                "radius=" + radius +
                ']';
    }

    Circle(int _radius){
        radius = _radius;
    }
    public int getPerimeter(){
        return (int)(2 * Math.PI * radius);
    }
    public int getArea(){
        return (int)(Math.PI * radius * radius);
    }
}

class Rectangle{
    private int width,length;

    @Override
    public String toString() {
        return "Rectangle [" +
                "width=" + width +
                ", length=" + length +
                ']';
    }

    Rectangle(int _width, int _length){
        width = _width;
        length = _length;
    }
    public int getPerimeter(){
        return 2 * (width + length);
    }
    public int getArea(){
        return width * length;
    }
}

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        Rectangle[] rectangles = new Rectangle[2];
        Circle[] circles = new Circle[2];
        int allPerimeter = 0, allArea = 0;
        for (int i = 0; i < 2; i++) {
            int w = scanner.nextInt();
            int l = scanner.nextInt();
            rectangles[i] = new Rectangle(w,l);
            allPerimeter += rectangles[i].getPerimeter();
            allArea += rectangles[i].getArea();
        }
        for (int i = 0; i < 2; i++) {
            int r = scanner.nextInt();
            circles[i] = new Circle(r);
            allPerimeter += circles[i].getPerimeter();
            allArea += circles[i].getArea();
        }
        System.out.println(allPerimeter);
        System.out.println(allArea);
        System.out.println(Arrays.deepToString(rectangles));
        System.out.println(Arrays.deepToString(circles));
    }
}
